package svgedit.gui.actions;

import java.awt.Color;
import java.awt.event.ActionEvent;
import java.util.ArrayList;
import java.util.Iterator;

import javax.swing.AbstractAction;

import svgedit.gui.Circle;
import svgedit.gui.Frame;
import svgedit.gui.Line;
import svgedit.gui.Rect;
import svgedit.gui.View;

public class DeleteAction extends AbstractAction{
    
	private Frame frame;
	public static ArrayList<Circle> circles = View.getCircles();
	public static ArrayList<Line> lines = View.getLines();
	public static ArrayList<Rect> rects = View.getRects();
	public static ArrayList<Color> colors = View.getColors();

    /** Create this action for the given frame */
    public DeleteAction(Frame frame) {
        super("Delete");
        this.frame = frame;
    }

	@Override
	public void actionPerformed(ActionEvent arg0) 
	{
    	frame.deleteSelected();
	}
}
